// ********************************************************************************************
// Este archivo fuente es propiedad de Feria de Remates S.R.L. de C.V. Prohibida su copia o uso
// sin autorización explícita.
// This source file is propietary to Feria de Remates S.R.L. de C.V. May not be used or copied
// without explicit authorization.
// ********************************************************************************************/
package com.feriaderemates.domain.listing;

import java.math.BigDecimal;
import java.util.List;

/**
 *
 * @author Oscar García
 */
public class FixedPriceListing extends Listing {

    public static FixedPriceListing createFixedPriceListing(String sellerUsername) {
        return new FixedPriceListing(sellerUsername);
    }

    private boolean acceptingReturns;
    private String returnRules;
    private int daysToProcessShipment;
    private List<ShippingCarrier> shippingCarriers;
    private BigDecimal price;
    private boolean acceptingOffers;
    private int quantity;
    private boolean requiresImmediatePayment;
    private ItemCondition itemCondition;
    private boolean canYouPickItUp;
    
    //fields when viewing details (not when inserting the listing)
    private int numberOfOffers; //non updatable by user
    private BigDecimal previousPrice; //non updatable by user
    
    
    private FixedPriceListing(String sellerUsername) {
        this.username = sellerUsername;
    }


    /**
     * @return the acceptingReturns
     */
    public boolean isAcceptingReturns() {
        return acceptingReturns;
    }

    /**
     * @param acceptingReturns the acceptingReturns to set
     */
    public void setAcceptingReturns(boolean acceptingReturns) {
        this.acceptingReturns = acceptingReturns;
    }

    /**
     * @return the returnRules
     */
    public String getReturnRules() {
        return returnRules;
    }

    /**
     * @param returnRules the returnRules to set
     */
    public void setReturnRules(String returnRules) {
        this.returnRules = returnRules;
    }

    /**
     * @return the daysToProcessShipment
     */
    public int getDaysToProcessShipment() {
        return daysToProcessShipment;
    }

    /**
     * @param daysToProcessShipment the daysToProcessShipment to set
     */
    public void setDaysToProcessShipment(int daysToProcessShipment) {
        this.daysToProcessShipment = daysToProcessShipment;
    }

    /**
     * @return the shippingCarriers
     */
    public List<ShippingCarrier> getShippingCarriers() {
        return shippingCarriers;
    }

    /**
     * @param shippingCarriers the shippingCarriers to set
     */
    public void setShippingCarriers(List<ShippingCarrier> shippingCarriers) {
        this.shippingCarriers = shippingCarriers;
    }

    /**
     * @return the price
     */
    public BigDecimal getPrice() {
        return price;
    }

    /**
     * @param price the price to set
     */
    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    /**
     * @return the acceptingOffers
     */
    public boolean isAcceptingOffers() {
        return acceptingOffers;
    }

    /**
     * @param acceptingOffers the acceptingOffers to set
     */
    public void setAcceptingOffers(boolean acceptingOffers) {
        this.acceptingOffers = acceptingOffers;
    }

    /**
     * @return the quantity
     */
    public int getQuantity() {
        return quantity;
    }

    /**
     * @param quantity the quantity to set
     */
    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }

    /**
     * @return the requiresImmediatePayment
     */
    public boolean isRequiresImmediatePayment() {
        return requiresImmediatePayment;
    }

    /**
     * @param requiresImmediatePayment the requiresImmediatePayment to set
     */
    public void setRequiresImmediatePayment(boolean requiresImmediatePayment) {
        this.requiresImmediatePayment = requiresImmediatePayment;
    }

    /**
     * @return the itemCondition
     */
    public ItemCondition getItemCondition() {
        return itemCondition;
    }

    /**
     * @param itemCondition the itemCondition to set
     */
    public void setItemCondition(ItemCondition itemCondition) {
        this.itemCondition = itemCondition;
    }

    /**
     * @return the sellerUsername
     */
    public String getSellerUsername() {
        return username;
    }

    /**
     * @return the numberOfOffers
     */
    public int getNumberOfOffers() {
        return numberOfOffers;
    }

    /**
     * @param numberOfOffers the numberOfOffers to set
     */
    public void setNumberOfOffers(int numberOfOffers) {
        this.numberOfOffers = numberOfOffers;
    }

    /**
     * @return the previousPrice
     */
    public BigDecimal getPreviousPrice() {
        return previousPrice;
    }

    /**
     * @param previousPrice the previousPrice to set
     */
    public void setPreviousPrice(BigDecimal previousPrice) {
        this.previousPrice = previousPrice;
    }

    /**
     * @return the canYouPickItUp
     */
    public boolean isCanYouPickItUp() {
        return canYouPickItUp;
    }

    /**
     * @param canYouPickItUp the canYouPickItUp to set
     */
    public void setCanYouPickItUp(boolean canYouPickItUp) {
        this.canYouPickItUp = canYouPickItUp;
    }

}
